<%@ Page Language="VB" StylesheetTheme="default" ValidateRequest="false" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="QuestionCreate.aspx.vb" Inherits="Modules_Questionnaires_QuestionCreate" title="Question Creator Page" %>
<%@ Register Assembly="DotNetPM.Web.UI.WebControls" TagPrefix="cc" Namespace="DotNetPM.Web.UI.WebControls" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

    <table id="Table2" cellpadding="2" cellspacing="2" width="100%">
        <tr>
            <td colspan="3">
                <strong><font size="2">QUESTION CREATOR</font></strong></td>
            <td align="right" colspan="1">
                <asp:HyperLink ID="hlBack" runat="server" NavigateUrl="QuestionManager.aspx" ForeColor="Blue" >Back</asp:HyperLink></td>
        </tr>
        <tr>
            <td colspan="4" valign="top">
                <hr size="1" width="100%" /><br /></td>
        </tr>
        <tr>
            <td rowspan="1" valign="top" width="15" height="400">
                &nbsp;</td>
            <td valign="top" height="300">
                
			    <TABLE id="Table1" cellSpacing="1" cellPadding="3" border="1" bordercolordark="#cccccc" bordercolorlight="#cccccc">
				    <TR>
					    <TD align="right" width="100"><strong>Category :</strong></TD>
                        <td colspan="2">
                            <asp:dropdownlist id="ddlCategory" runat="server" DataSourceID="CategoryODS" DataTextField="Name" DataValueField="ID"></asp:dropdownlist>
						    <asp:Button id="butCatEdit" runat="server" Text="Edit" CausesValidation="False"></asp:Button>
                            <asp:ObjectDataSource ID="CategoryODS" runat="server" OldValuesParameterFormatString="original_{0}"
                                SelectMethod="GetCategories" TypeName="DotNetPM.Business.Questionnaire.CategoryODS">
                            </asp:ObjectDataSource>
                            &nbsp;
                        </td>
				    </TR>
				    <TR>
					    <TD align="right" style="height: 110px">
						    <P><strong>Question :</strong><br>
							    (Max. 1,000 chars)</P>
					    </TD>
                        <td colspan="2" style="height: 110px">
                            <table border=0 cellpadding="0" cellspacing="0">
                                <tr>
                                    <td style="height: 148px">
                                        <cc:CountTextBox id="txtQuestion" runat=server TextMode="MultiLine" Width="560px" Rows="8" MaxLength="1000" />
					                </td>
                                    <td style="height: 148px" >
                                        <asp:RequiredFieldValidator id="RequiredFieldValidator1" runat="server" ErrorMessage="Question field cannot be blank."
						                ControlToValidate="txtQuestion">*</asp:RequiredFieldValidator>
                                    </td>
                                </tr>
                            </table>
                        </td>
				    </TR>
				    <TR>
					    <TD style="HEIGHT: 22px" align="right"><strong>Image :</strong></TD>
                        <td colspan="2" style="height: 22px">
                            Will be save at the qImages folder with the name of 
						    Question Number.</td>
				    </TR>
				    <TR>
					    <TD style="HEIGHT: 19px" align="right">
                            <strong>Answer Type :</strong></TD>
                        <td colspan="2" style="height: 19px">
                            <asp:dropdownlist id="ddlType" runat="server" AutoPostBack="True" DataSourceID="ControlXDS" 
                            DataTextField="name" DataValueField="id"></asp:dropdownlist>
                            <asp:XmlDataSource ID="ControlXDS" runat="server" DataFile="~/Secure/Controls/ControlList.xml">
                            </asp:XmlDataSource>
                        </td>
				    </TR>
				    <TR>
					    <TD align="right" style="height: 21px"><strong>Configuraton :</strong></TD>
                        <td colspan="2" style="height: 21px">
                            <asp:placeholder id="ph1" runat="server"></asp:placeholder></td>
				    </TR>
                    <tr>
                        <td align="right" colspan="3" style="height: 21px">
                            <asp:HiddenField ID="hfQuestionId" runat="server" />
                            &nbsp;<asp:button id="butCreate" runat="server" Text="Create" Width="75px"></asp:button>&nbsp;
                            <asp:Button ID="butUpdate" runat="server" Text="Update" Width="75px" />&nbsp;
                            <asp:Button ID="butCancel" runat="server" CausesValidation="False" Text="Cancel" Width="75px" /></td>
                    </tr>
			    </TABLE>
			<asp:ValidationSummary id="ValidationSummary1" runat="server"></asp:ValidationSummary>
			
            </td>
            <td colspan="2"  valign="top">
                &nbsp;
            </td>
        </tr>
    </table>
		
</asp:Content>

